/*
 *  This file is part of the SIRIUS libraries for analyzing MS and MS/MS data
 *
 *  Copyright (C) 2024 Bright Giant GmbH
 *
 *  This library is free software; you can redistribute it and/or
 *  modify it under the terms of the GNU Lesser General Public
 *  License as published by the Free Software Foundation; either
 *  version 2.1 of the License, or (at your option) any later version.
 *
 *  This library is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 *  Lesser General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License along with SIRIUS.  If not, see <http://www.gnu.org/licenses/>.
 *
 *  NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 *  https://openapi-generator.tech
 *  Do not edit the class manually.
 */


package io.sirius.ms.sdk.model;

import java.util.Objects;
import java.util.Arrays;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.fasterxml.jackson.annotation.JsonValue;
import io.sirius.ms.sdk.model.CompoundClass;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.annotation.JsonTypeName;

/**
 * Container class that holds the most likely compound class for different levels of each ontology for a  certain Compound/Feature/FormulaCandidate/PredictedFingerprint.
 */
@JsonPropertyOrder({
  CompoundClasses.JSON_PROPERTY_NPC_PATHWAY,
  CompoundClasses.JSON_PROPERTY_NPC_SUPERCLASS,
  CompoundClasses.JSON_PROPERTY_NPC_CLASS,
  CompoundClasses.JSON_PROPERTY_CLASSY_FIRE_LINEAGE,
  CompoundClasses.JSON_PROPERTY_CLASSY_FIRE_ALTERNATIVES
})
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.14.0")
public class CompoundClasses {
  public static final String JSON_PROPERTY_NPC_PATHWAY = "npcPathway";
  @jakarta.annotation.Nullable
  private CompoundClass npcPathway;

  public static final String JSON_PROPERTY_NPC_SUPERCLASS = "npcSuperclass";
  @jakarta.annotation.Nullable
  private CompoundClass npcSuperclass;

  public static final String JSON_PROPERTY_NPC_CLASS = "npcClass";
  @jakarta.annotation.Nullable
  private CompoundClass npcClass;

  public static final String JSON_PROPERTY_CLASSY_FIRE_LINEAGE = "classyFireLineage";
  @jakarta.annotation.Nullable
  private List<CompoundClass> classyFireLineage;

  public static final String JSON_PROPERTY_CLASSY_FIRE_ALTERNATIVES = "classyFireAlternatives";
  @jakarta.annotation.Nullable
  private List<CompoundClass> classyFireAlternatives;

  public CompoundClasses() {
  }

  public CompoundClasses npcPathway(@jakarta.annotation.Nullable CompoundClass npcPathway) {
    
    this.npcPathway = npcPathway;
    return this;
  }

  /**
   * Get npcPathway
   * @return npcPathway
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_NPC_PATHWAY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public CompoundClass getNpcPathway() {
    return npcPathway;
  }


  @JsonProperty(JSON_PROPERTY_NPC_PATHWAY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setNpcPathway(@jakarta.annotation.Nullable CompoundClass npcPathway) {
    this.npcPathway = npcPathway;
  }

  public CompoundClasses npcSuperclass(@jakarta.annotation.Nullable CompoundClass npcSuperclass) {
    
    this.npcSuperclass = npcSuperclass;
    return this;
  }

  /**
   * Get npcSuperclass
   * @return npcSuperclass
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_NPC_SUPERCLASS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public CompoundClass getNpcSuperclass() {
    return npcSuperclass;
  }


  @JsonProperty(JSON_PROPERTY_NPC_SUPERCLASS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setNpcSuperclass(@jakarta.annotation.Nullable CompoundClass npcSuperclass) {
    this.npcSuperclass = npcSuperclass;
  }

  public CompoundClasses npcClass(@jakarta.annotation.Nullable CompoundClass npcClass) {
    
    this.npcClass = npcClass;
    return this;
  }

  /**
   * Get npcClass
   * @return npcClass
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_NPC_CLASS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public CompoundClass getNpcClass() {
    return npcClass;
  }


  @JsonProperty(JSON_PROPERTY_NPC_CLASS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setNpcClass(@jakarta.annotation.Nullable CompoundClass npcClass) {
    this.npcClass = npcClass;
  }

  public CompoundClasses classyFireLineage(@jakarta.annotation.Nullable List<CompoundClass> classyFireLineage) {
    
    this.classyFireLineage = classyFireLineage;
    return this;
  }

  public CompoundClasses addClassyFireLineageItem(CompoundClass classyFireLineageItem) {
    if (this.classyFireLineage == null) {
      this.classyFireLineage = new ArrayList<>();
    }
    this.classyFireLineage.add(classyFireLineageItem);
    return this;
  }

  /**
   * Most likely ClassyFire lineage from ordered from least specific to most specific class  classyFireLineage.get(classyFireLineage.size() - 1) gives the most specific ClassyFire compound class annotation
   * @return classyFireLineage
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_CLASSY_FIRE_LINEAGE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public List<CompoundClass> getClassyFireLineage() {
    return classyFireLineage;
  }


  @JsonProperty(JSON_PROPERTY_CLASSY_FIRE_LINEAGE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setClassyFireLineage(@jakarta.annotation.Nullable List<CompoundClass> classyFireLineage) {
    this.classyFireLineage = classyFireLineage;
  }

  public CompoundClasses classyFireAlternatives(@jakarta.annotation.Nullable List<CompoundClass> classyFireAlternatives) {
    
    this.classyFireAlternatives = classyFireAlternatives;
    return this;
  }

  public CompoundClasses addClassyFireAlternativesItem(CompoundClass classyFireAlternativesItem) {
    if (this.classyFireAlternatives == null) {
      this.classyFireAlternatives = new ArrayList<>();
    }
    this.classyFireAlternatives.add(classyFireAlternativesItem);
    return this;
  }

  /**
   * Alternative ClassyFire classes with high probability that do not fit into the linage
   * @return classyFireAlternatives
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_CLASSY_FIRE_ALTERNATIVES)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public List<CompoundClass> getClassyFireAlternatives() {
    return classyFireAlternatives;
  }


  @JsonProperty(JSON_PROPERTY_CLASSY_FIRE_ALTERNATIVES)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setClassyFireAlternatives(@jakarta.annotation.Nullable List<CompoundClass> classyFireAlternatives) {
    this.classyFireAlternatives = classyFireAlternatives;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    CompoundClasses compoundClasses = (CompoundClasses) o;
    return Objects.equals(this.npcPathway, compoundClasses.npcPathway) &&
        Objects.equals(this.npcSuperclass, compoundClasses.npcSuperclass) &&
        Objects.equals(this.npcClass, compoundClasses.npcClass) &&
        Objects.equals(this.classyFireLineage, compoundClasses.classyFireLineage) &&
        Objects.equals(this.classyFireAlternatives, compoundClasses.classyFireAlternatives);
  }

  @Override
  public int hashCode() {
    return Objects.hash(npcPathway, npcSuperclass, npcClass, classyFireLineage, classyFireAlternatives);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class CompoundClasses {\n");
    sb.append("    npcPathway: ").append(toIndentedString(npcPathway)).append("\n");
    sb.append("    npcSuperclass: ").append(toIndentedString(npcSuperclass)).append("\n");
    sb.append("    npcClass: ").append(toIndentedString(npcClass)).append("\n");
    sb.append("    classyFireLineage: ").append(toIndentedString(classyFireLineage)).append("\n");
    sb.append("    classyFireAlternatives: ").append(toIndentedString(classyFireAlternatives)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}

